﻿using System;
using System.Collections.Generic;

namespace com.igetui.api.openservice
{
	// Token: 0x02000026 RID: 38
	public class GtConfig
	{
		// Token: 0x0600045B RID: 1115 RVA: 0x000097BC File Offset: 0x000079BC
		public static bool isPushSingleBatchAsync()
		{
			string environmentVariable = Environment.GetEnvironmentVariable("gexin_pushSingleBatch_needAsync");
			return "true".Equals(environmentVariable);
		}

		// Token: 0x0600045C RID: 1116 RVA: 0x000097E0 File Offset: 0x000079E0
		public static bool isPushListAsync()
		{
			string environmentVariable = Environment.GetEnvironmentVariable("gexin_pushList_needAsync");
			return "true".Equals(environmentVariable);
		}

		// Token: 0x0600045D RID: 1117 RVA: 0x00009804 File Offset: 0x00007A04
		public static bool isPushListNeedDetails()
		{
			string environmentVariable = Environment.GetEnvironmentVariable("gexin_pushList_needDetails");
			string environmentVariable2 = Environment.GetEnvironmentVariable("needDetails");
			if (environmentVariable2 != null)
			{
				return environmentVariable2.Equals("true");
			}
			return environmentVariable != null && environmentVariable.Equals("true");
		}

		// Token: 0x0600045E RID: 1118 RVA: 0x00009846 File Offset: 0x00007A46
		public static string getHttpProxyIp()
		{
			return Environment.GetEnvironmentVariable("gexin_http_proxy_ip");
		}

		// Token: 0x0600045F RID: 1119 RVA: 0x00009854 File Offset: 0x00007A54
		public static int getHttpProxyPort()
		{
			string environmentVariable = Environment.GetEnvironmentVariable("gexin_http_proxy_port");
			if (environmentVariable != null)
			{
				return int.Parse(environmentVariable);
			}
			return 80;
		}

		// Token: 0x06000460 RID: 1120 RVA: 0x00009878 File Offset: 0x00007A78
		public static string getHttpProxyUser()
		{
			return Environment.GetEnvironmentVariable("gexin_http_proxy_username");
		}

		// Token: 0x06000461 RID: 1121 RVA: 0x00009884 File Offset: 0x00007A84
		public static string getHttpProxyPasswd()
		{
			return Environment.GetEnvironmentVariable("gexin_http_proxy_passwd");
		}

		// Token: 0x06000462 RID: 1122 RVA: 0x00009890 File Offset: 0x00007A90
		public static int getSyncListLimit()
		{
			string environmentVariable = Environment.GetEnvironmentVariable("gexin_pushList_syncLimit");
			if (environmentVariable != null)
			{
				return int.Parse(environmentVariable);
			}
			return 1000;
		}

		// Token: 0x06000463 RID: 1123 RVA: 0x000098B8 File Offset: 0x00007AB8
		public static int getAsyncListLimit()
		{
			string environmentVariable = Environment.GetEnvironmentVariable("gexin_pushList_asyncLimit");
			if (environmentVariable != null)
			{
				return int.Parse(environmentVariable);
			}
			return 10000;
		}

		// Token: 0x06000464 RID: 1124 RVA: 0x000098E0 File Offset: 0x00007AE0
		public static int getHttpConnectionTimeOut()
		{
			string environmentVariable = Environment.GetEnvironmentVariable("gexin_http_connection_timeout");
			if (environmentVariable != null)
			{
				return int.Parse(environmentVariable);
			}
			return 60000;
		}

		// Token: 0x06000465 RID: 1125 RVA: 0x00009908 File Offset: 0x00007B08
		public static int getHttpSoTimeOut()
		{
			string environmentVariable = Environment.GetEnvironmentVariable("gexin_http_so_timeout");
			if (environmentVariable != null)
			{
				return int.Parse(environmentVariable);
			}
			return 30000;
		}

		// Token: 0x06000466 RID: 1126 RVA: 0x00009930 File Offset: 0x00007B30
		public static int getHttpTryCount()
		{
			string environmentVariable = Environment.GetEnvironmentVariable("gexin_http_tryCount");
			if (environmentVariable != null)
			{
				return int.Parse(environmentVariable);
			}
			return 3;
		}

		// Token: 0x06000467 RID: 1127 RVA: 0x00009954 File Offset: 0x00007B54
		public static int getHttpInspectInterval()
		{
			string environmentVariable = Environment.GetEnvironmentVariable("gexin_http_inspect_interval");
			if (environmentVariable != null)
			{
				return int.Parse(environmentVariable);
			}
			return 60000;
		}

		// Token: 0x06000468 RID: 1128 RVA: 0x0000997C File Offset: 0x00007B7C
		public static List<string> getDefaultDomainUrl(bool useSSL)
		{
			List<string> list = new List<string>();
			string environmentVariable = Environment.GetEnvironmentVariable("gexin_default_domainurl");
			if (environmentVariable == null || "".Equals(environmentVariable.Trim()))
			{
				if (useSSL)
				{
					list.Add("https://cncapi.getui.com/serviceex");
					list.Add("https://telapi.getui.com/serviceex");
					list.Add("https://api.getui.com/serviceex");
					list.Add("https://sdk1api.getui.com/serviceex");
					list.Add("https://sdk2api.getui.com/serviceex");
					list.Add("https://sdk3api.getui.com/serviceex");
				}
				else
				{
					list.Add("http://sdk.open.api.igexin.com/serviceex");
					list.Add("http://sdk.open.api.gepush.com/serviceex");
					list.Add("http://sdk.open.api.getui.net/serviceex");
					list.Add("http://sdk1.open.api.igexin.com/serviceex");
					list.Add("http://sdk2.open.api.igexin.com/serviceex");
					list.Add("http://sdk3.open.api.igexin.com/serviceex");
				}
			}
			else
			{
				foreach (string text in environmentVariable.Split(new char[]
				{
					','
				}))
				{
					if ((!text.StartsWith("https://") || useSSL) && (!text.StartsWith("http://") || !useSSL))
					{
						if (!text.StartsWith("http") && useSSL)
						{
							list.Add("https://" + text);
						}
						else
						{
							list.Add(text);
						}
					}
				}
			}
			return list;
		}

		// Token: 0x06000469 RID: 1129 RVA: 0x00009AB8 File Offset: 0x00007CB8
		public static int getTransIntentLength()
		{
			string environmentVariable = Environment.GetEnvironmentVariable("trans_intent_length");
			if (environmentVariable != null)
			{
				return int.Parse(environmentVariable);
			}
			return 1000;
		}

		// Token: 0x0600046A RID: 1130 RVA: 0x00009ADF File Offset: 0x00007CDF
		public static string getSDKVersion()
		{
			return "4.0.1.5";
		}
	}
}
